Bit-parallel string matching under Hamming distance in O(n[m/w]) worst case time

نویسندگان

  • Szymon Grabowski
  • Kimmo Fredriksson
چکیده

Given two strings, a pattern P of length m and a text T of length n over some alphabet Σ, we consider the string matching problem under k mismatches. The well– known Shift-Add algorithm (Baeza-Yates and Gonnet, 1992) solves the problem in O(ndm log(k)/we) worst case time, where w is the number of bits in a computer word. We present two algorithms that improve this result to O(ndm log log(k)/we) and O(ndm/we), respectively. The algorithms make use of nested varying length bit-strings, that represent the search state. We call these Matryoshka counters. The techniques we developed are of more general use for string matching problems.

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

منابع مشابه

Practical and Optimal String Matching

We develop a new exact bit-parallel string matching algorithm, based on the Shift-Or algorithm (Baeza-Yates & Gonnet, 1992). Assuming that the pattern representation fits into a single computer word, this algorithm has optimal O(n logσ m/m) average running time, as well as optimal O(n) worst case running time, where n, m and σ are the sizes of the text, the pattern, and the alphabet, respective...

متن کامل

On the inverse maximum perfect matching problem under the bottleneck-type Hamming distance

Given an undirected network G(V,A,c) and a perfect matching M of G, the inverse maximum perfect matching problem consists of modifying minimally the elements of c so that M becomes a maximum perfect matching with respect to the modified vector. In this article, we consider the inverse problem when the modifications are measured by the weighted bottleneck-type Hamming distance. We propose an alg...

متن کامل

Efficient Bit-parallel Algorithms for (δ, α)-matching

We consider the following string matching problem. Pattern p0p1p2 . . . pm−1 (δ, α)-matches the text substring ti0 ti1ti2 . . . tim−1 , if |pj − tij | ≤ δ for j ∈ {0, . . . , m− 1}, where 0 < ij+1 − ij ≤ α + 1. The task is then to find all text positions im−1 that (δ, α)-match the pattern. For a text of length n, the best previously known algorithms for this string matching problem run in time ...

متن کامل

Bit-parallel (δ, γ)-Matching and Suffix Automata

(δ, γ )-matching is a string matching problem with applications to music retrieval. The goal is, given a pattern P1...m and a text T1...n on an alphabet of integers, find the occurrences P ′ of the pattern in the text such that (i) ∀1 i m, |Pi−P ′ i | δ, and (ii) ∑ 1 i m |Pi−P ′ i | γ . The problem makes sense for δ γ δm. Several techniques for (δ, γ )-matching have been proposed, based on bit-...

متن کامل

ذخیره در منابع من


  با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

عنوان ژورنال:
  • Inf. Process. Lett.

دوره 105  شماره 

صفحات  -

تاریخ انتشار 2008